<!--div class="center jumbotron"-->
<%# Prefer the users.new locale text. That way, translators don't need to
    translate more than once, and in addition we'll use consistent terms. %>
 <br>
 <h1 class="center"><%= t('.update_user_info') %></h1>

 <div class="row">
   <div class="col-md-6 col-md-offset-3">
     <%= form_for(@user) do |f| %>
       <%= render 'shared/error_messages', object: f.object %>
       <%= f.label :name, t('users.new.name') %>
       <%= f.text_field :name, class:"form-control" %>

       <%= f.label :email, t('users.new.email') %>
       <%= f.email_field :email, class:"form-control" %>

       <%= f.label :preferred_locale, t('users.new.preferred_locale') %>
       <%=
         locale_names = I18n.available_locales.map do |loc|
           [t("locale_name.#{loc.to_s}"), loc.to_s]
         end
         f.select :preferred_locale, locale_names, {}, {class: "form-control"}
       %>

       <%= f.label :notification_emails, t('users.edit.notification_emails') %>
       <%= f.check_box :notification_emails, class: "form-check-input" %>
       <small class="form-text text-muted"><%= t('users.edit.notification_emails_help') %></small>

       <% if @user.provider == 'local' %>
         <%= f.label :password, t('users.new.password') %>
         <%= f.password_field :password, autocomplete: "off", class:"form-control" %>

         <%= f.label :password_confirmation, t('users.new.password_confirmation') %>
         <%= f.password_field :password_confirmation, autocomplete: "off", class:"form-control" %>
       <% end %>

       <%= f.submit t('.save_changes'), class: "btn btn-primary" %>
     <% end %>
   </div>
 </div>

</div>
